package org.jeecg.common.modules.sys.service;

import com.baomidou.mybatisplus.extension.service.IService;
import org.jeecg.common.modules.sys.entity.SysAccountFlow;
import org.jeecg.common.util.enums.SysAccountFlowTypeEnum;

import java.math.BigDecimal;

/**
 * @author guoyh
 * @ClassName SysAccountService
 * @Description
 * @since 2020/9/5 16:08
 **/
public interface ISysAccountFlowService extends IService<SysAccountFlow> {

    /**
     * 新增一条流水
     * @param sysAccountId
     * @param flowType
     * @param amount
     * @param relationId
     * @param createUser
     */
    void addAccountFlow(Long sysAccountId, SysAccountFlowTypeEnum flowType, BigDecimal amount, String relationId,String createUser);


    /**
     * 获取指定的流水
     * @param sysAccountId
     * @param flowType
     * @param relationId
     * @return
     */
    SysAccountFlow getSysAccountFlow(Long sysAccountId,SysAccountFlowTypeEnum flowType,String relationId);
}
